<?php use_helper('jQuery')?>

<?php if (count($photos)>=1):?>
	<div id="status"></div>
	<?php $last = count($photos)-1;
		foreach($photos as $i => $Photo):?>
		<div class="photo_list_item" id="media<?php echo $Photo->getId()?>">
				<a href="/uploads/media/thumbnail_600_600_p/<?php echo $Photo->getImage()?>"><img src="/uploads/media/thumbnail_40_40_n/<?php echo $Photo->getImage()?>" /></a><br/>
				<?php echo jq_link_to_remote(image_tag('delete_quest.png',array('title'=>'Удалить')),array(
						'update'=>'status',
						'url'=>'default/delete?media_id='.$Photo->getId(),
						'confirm'=>'Вы уверены?',
						'loading' => jq_visual_effect('fadeIn',  '#status'),
      					'complete'=> jq_visual_effect('fadeOut', '#status').';$("#media'.$Photo->getId().'").remove()'
					))?>
				
				
		</div>
	<?php endforeach;?>
<?php else:?>
Фото отсутствуют
<?php endif;?>
<div class="clear">&nbsp;</div>